﻿CREATE PROCEDURE [dbo].[proc_Department_Delete]
	(
		@Id int
	)
AS
	IF((select count(Id) From employee where departmentid=@Id and state <> 5) = 0)
		Begin
			Delete From Department Where Id=@Id
		End
	RETURN